home *** CD-ROM | disk | FTP | other *** search
/ The X-Philes (2nd Revision) / The X-Philes Number 1 (1995).iso / xphiles / hp48hor1 / tdir.doc < prev    next >
Text File  |  1995-03-31  |  3KB  |  61 lines

  1. (Comp.sys.handhelds) 
  2. Item: 3540 by ftg0673 at tamsun.TAMU.EDU 
  3. Author: [Rick Grevelle] 
  4.   Subj: HP48 Temporary Directories 
  5.   Date: Fri Jun 21 1991 
  6.  
  7. Using directories in the 48 has its share of disadvantages.  My personal 
  8. preference is not to use them at all.  Overall, directories access their 
  9. variables slower than libraries, and since they must be stored in the RAM 
  10. in order to be effectively used, there is less memory available for the 
  11. 48 to operate, increasing the frequency of memory packing, and resulting 
  12. in even slower execution timings. 
  13.  
  14. In a recent discussion with one of the most knowledgeable individuals of 
  15. whom I know outside of HP regarding the 48, I realized that there must be 
  16. many users who have yet to see how easy it is to incorporate a directory 
  17. type format into libraries, and altogether dump the directory habit :-). 
  18.  
  19. Unfortunately, one very convenient feature for doing this was not provided 
  20. by HP on the user language level.  So some time ago I developed a program 
  21. to deal with this deficiency.  Very similar to the TMENU command, TDIR has 
  22. an analogous role for directories.  Temporary directories are used in the 
  23. the 48 quite often; such keys as MTH, and PRG invoke such directories, and 
  24. are no different from the the TDIR command being introduced here. 
  25.   
  26. Any list that can be used as a valid argument for the TMENU command can be 
  27. easily modified to be used as a valid argument for the TDIR command.  All 
  28. that is necessary to do is to put the name of the temporary directory in a 
  29. string in level two, and then the argument list which is normally used by 
  30. TMENU in level one.  Combine the two arguments into a single list by using 
  31. the 2 ->LIST sequence.  This is the form in which the argument list must 
  32. be in order for TDIR to properly function.  Here's an example argument: 
  33.  
  34.  
  35. { { "UC" { AND OR XOR NOT  
  36. { "dup" \<< # 3188h SYSEVAL \>> } 
  37. { "drop" \<< # 3244h SYSEVAL \>> } 
  38. } } } 
  39.  
  40.  
  41. Multiple directories can be used with TDIR, and when more than six are used, 
  42. the NXT key will display the next page of directories just like TMENU does 
  43. when more than six menus are used.  Probably the quickest example that I can 
  44. think of is to combine the MTH, and PRG keys into a one temporary directory. 
  45.  
  46.  
  47. \<<  # 3B551h SYSEVAL # 3B293h SYSEVEL + TDIR \>> 
  48.  
  49.  
  50. Executing the above will immediately result in the combination of the two keys 
  51. MTH, and PRG, so each time the NXT key is pressed the next page of temporary 
  52. directories will appear.  There is no limit, other than memory constraints, to 
  53. the number of temporary directories than can be used together in this manner. 
  54.  
  55. Below is a directory that contains the TDIR command along with the sample list 
  56. from the earlier example.  Users already familiar with the use of TMENUs will 
  57. have a slight advantage here, but I feel this material is sufficiently 
  58. straightforward enough for everyone. 
  59.  
  60. Rick Grevelle 
  61.